<?php
/**
 * +-------------------------------------------------------------
 * |Caption:
 * +-------------------------------------------------------------
 * |Author: Lenny
 * +-------------------------------------------------------------
 * |Email:  1685964109@qq.com
 * +-------------------------------------------------------------
 * |Date:   2024/7/3 下午3:05
 * +-------------------------------------------------------------
 */

namespace app\admin\validate;

use think\Validate;

class CategoryValidate extends Validate
{

    protected $rule = [
        'name' => 'require|max:25',
    ];

    protected $message = [
        'name.require' => '分类名称不能为空',
        'name.max' => '分类名称不能超过25个字符',
    ];

    protected $scene = [
            'add'=>['title']
    ];
}